package com.ruoyi.system.domain.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * @Author: ChenHaiDong
 * @CreateTime: 2023-03-11  15:59
 * @Description: TODO 货柜货物列表
 * @Version: 1.0
 */
@Data
public class CounterGoodsListVo {

    /** 货物id */
    private Integer id;

    /** 客户名称 */
    @Excel(name = "客户名称")
    private String customerName;

    /** 客户代码 */
    @Excel(name = "客户代码")
    private String customerCode;

    /** 客户手机号 */
    @Excel(name = "客户手机号")
    private String customerPhone;

    /** 货物名称 */
    @Excel(name = "货物名称")
    private String goodsName;

    /** 总件数 */
    @Excel(name = "总件数")
    private Double total;

    /** 包装数量 */
    @Excel(name = "包装数量")
    private Integer packageNum;

    /** 货物体积 */
    @Excel(name = "货物体积")
    private Double goodsSize;

    /** 创建时间 */
    @Excel(name = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    public Double getTotal() {
        return total == null ? 0 : total;
    }

    public Integer getPackageNum() {
        return packageNum == null ? 0 :packageNum;
    }

    public Double getGoodsSize() {
        return goodsSize == null ? 0 : goodsSize;
    }

}
